Pod::Spec.new do |s|
  s.name     = 'AVOSCloudCrashReporting'
  s.version  = '{{{version}}}'
  s.homepage = 'https://leancloud.cn/'
  s.summary  = 'LeanCloud Crash Reporting Objective-C SDK'
  s.authors  = 'LeanCloud'
  s.license  = {
    :type => 'Apache License, Version 2.0',
    :file => 'LICENSE'
  }

  s.platform = :ios

  s.ios.deployment_target = '7.0'

  s.source = {
    :git => "https://github.com/leancloud/objc-sdk.git",
    :tag => "#{s.version}",
    :submodules => true
  }

  {{#_ARC}}
  s.subspec '_ARC' do |ss|
    ss.requires_arc = true
    ss.dependency 'AVOSCloudCrashReporting/_NOARC', "#{s.version}"

    {{#source_files}}
    ss.source_files =
      {{{source_files}}}
    {{/source_files}}
  end
  {{/_ARC}}

  {{#_NOARC}}
  s.subspec '_NOARC' do |ss|
    ss.requires_arc = false

    {{#source_files}}
    ss.source_files =
      {{{source_files}}}
    {{/source_files}}

    {{#public_header_files}}
    ss.public_header_files =
      {{{public_header_files}}}
    {{/public_header_files}}

    {{#preserve_paths}}
    ss.preserve_paths =
      {{{preserve_paths}}}
    {{/preserve_paths}}

    {{#pod_target_xcconfig}}
    ss.pod_target_xcconfig = {{{pod_target_xcconfig}}}
    {{/pod_target_xcconfig}}
  end
  {{/_NOARC}}

  s.dependency 'AVOSCloud', "#{s.version}"

  s.libraries =
    'c++'
end
